var config = {};

config.api = [{

    module : "用户",
    payload : [ {
        name : "用户",
        path : "user/all",
        path2 : "user/all",
        method : "get",
        params : {
            "id": "1",
        }
    }]
}]





var _attachId = function(api) {
    for (var i = 0; i < api.length; i++) {
        var mid = "m" + i;
        api[i].id = mid;
        var pd = api[i].payload;
        for (var j = 0; j < pd.length; j++) {
            var aid = "i" + j;
            pd[j].id = mid + aid;

        }
    }

};
_attachId(config.api);